﻿
@{
    Layout = null;
}

<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <title></title>
    <link href="~/layui/css/layui.css" rel="stylesheet" />
    <style>
* {
	margin: 0;
	padding: 0;
}

html {
	width: 1100px;
	height: 100%;
	margin: 0 auto;
}

html body {
	border: 0px solid #000;
	width: 100%;
	height: 100%;
}

html body h2 {
	border: 0px solid #000;
	border-bottom: none;
	height: 48px;
	line-height: 48px;
	width: 100%;
	text-align: center;
}

.row1 {
	width: 100%;
	border: 1px solid #000;
	height: 85px;
	list-style: none;
	border-bottom: none;
}

.row1 li {
	border-bottom: 1px solid #000;
	float: left;
	height: 42.1px;
	width: 49.955%;
	line-height: 42.5px;
	font-size: 15px;
	font-weight: 600;
}

.row1 li input {
	border: none;
	width: 400px;
	height: 80%;
	font-size: 14px;
	font-weight: 600;
	outline: none;
}

.row2 {
	border: 1px solid #000;
	border-top: none;
	height: 240px;
	width: 100%;
	list-style: none;
}

.row2 li {
	border-right: 1px solid #000;
	float: left;
	display: flex;
	align-items: center;
	justify-content: center;
	font-weight: 600;
}
.row3 {
	border: 1px solid #000;
	height: 50px;
	width: 100%;
	border-top: none;
	font-weight: 600;
	display: flex;
	align-items: center;
	justify-content: flex-start;
}
.row4{
	height: 150px;
	border:1px solid #000;
	width: 100%;
	border-top: none;
	list-style: none;

}
.row4 li {
	float: left;
	display: flex;
	align-items: center;
	justify-content: center;
	font-weight: 600;
}
.row5 {
	border: 1px solid #000;
	border-top: none;
	width: 100%;
	height: 80px;
}
.row5 .row5_1{
	width:10%;
	height:100%;
	display: flex;
	align-items: center;
	float: left;
	font-weight: 600;
}
.row5 .row5_2{
	width:89.9%;
	height:100%;
	display: flex;
	align-items: center;
	justify-content: center;
	float: left;
}
.row6 {
	border: 1px solid #000;
	border-top: none;
	width: 100%;
	height: 80px;
}
.row6 .row6_1{
	width:50%;
	height:100%;
	display: flex;
	align-items: center;
	float: left;
	font-weight: 600;
	border-right: 1px solid #000;
}
.row6 .row6_2{
	width:49.9%;
	height:100%;
	display: flex;
	align-items: center;
	float: left;
	font-weight: 600;
	border-right: none;
}
.row7 {
	border: 1px solid #000;
	border-top: none;
	width: 100%;
	height: 80px;
}
.row7 .row7_1{
	width:10%;
	height:100%;
	display: flex;
	align-items: center;
	justify-content: center;
	float: left;
	font-weight: 600;
	border-right: 1px solid #000;
}
.row7 .row7_2{
	width:89.9%;
	height:100%;
	display: flex;
	align-items: center;
	justify-content: center;
	float: left;
}
    </style>
</head>
<body>
    <form class="layui-form" action="" lay-filter="example">

        <input type="hidden" name="BillNameID" value="@ViewBag.BillNameID" />
        <input type="hidden" name="BillProID" value="@ViewBag.ProID" />
        <input type="hidden" name="ID" value="@ViewBag.Model.ID" />
        <h2>储能环焊特殊工序首件检验记录</h2>
        <ul class="row1">
            <li style="border-right: 1px solid #000;">产品型号:<input type="text" name="Field1" id="Field1" /></li>
            <li>生产批号:<input type="text" name="Field2" id="Field2" /></li>
            <li style="border-right: 1px solid #000;">封帽设备型号:<input type="text" name="Field3" id="Field3" /></li>
            <li>编号/有效期:<input type="text" name="Field4" id="Field4" /></li>
        </ul>
        <ul class="row2">
            <li style="width:20%;height: 100%;border-right: 1px solid #000;">工艺参数</li>
            <li style="width:10%;height: 50%;border: 1px solid #000;border-left: none;border-top: none;">前烘</li>
            <li style="width:35%;height: 25%;border: 1px solid #000;border:1px solid #000;border-left: none;border-top: none;">排潮温度(℃)</li>
            <li style="width:34.728%;height: 25%;border-bottom: 1px solid #000;border-right: none;">排潮时间(h)</li>
            <li style="width:35%;height: 24.7%;border: 1px solid #000;border-top: none;border-left: none;">
                <textarea name="Field5" id="Field5" style="width: 80%;height: 80%;border:none;outline: none;font-size: 14px;font-weight: 600;"></textarea>
            </li>
            <li style="width:34.728%;height: 24.7%;border-bottom: 1px solid #000;border:1px solid #000;border-left: none;border-top: none;border-right: none;">
                <textarea name="Field6" id="Field6" style="width: 80%;height: 80%;border:none;outline: none;font-size: 14px;font-weight: 600;"></textarea>
            </li>
            <li style="width:10%;height: 49.5%;border: 1px solid #000;border-left: none;border-top: none;border-bottom: none;">封装</li>
            <li style="width: 23.2%;height: 25%;border: 1px solid #000;border-left: none;border-top: none;">封装电压(V)</li>
            <li style="width: 23.2%;height: 25%;border: 1px solid #000;border-left: none;border-top: none;">封装气压(PSI)</li>
            <li style="width: 23.24%;height: 25%;border-bottom: 1px solid #000;border-right: none;">放电时间(cycles)</li>
            <li style="width: 23.2%;height: 24%;border: 1px solid #000;border-left: none;border-top: none;border-bottom: none;">
                <textarea name="Field7" id="Field7" style="width: 80%;height: 80%;border:none;outline: none;font-size: 14px;font-weight: 600;"></textarea>
            </li>
            <li style="width: 23.2%;height: 24%;border: 1px solid #000;border-left: none;border-top: none;border-bottom: none;">
                <textarea name="Field8" id="Field8" style="width: 80%;height: 80%;border:none;outline: none;font-size: 14px;font-weight: 600;"></textarea>
            </li>
            <li style="width: 23.24%;height: 23.5%;border-right: none;">
                <textarea name="Field9" id="Field9" style="width: 80%;height: 80%;border:none;outline: none;font-size: 14px;font-weight: 600;"></textarea>
            </li>
        </ul>
        <div class="row3">
            首件样品第<input style="border: none;width:70px;height: 80%;font-size: 14px;font-weight: 600;outline: none;" type="text">次提交
        </div>
        <ul class="row4">
            <li style="width: 20%;height: 33%;border-bottom: 1px solid #000;border-right: 1px solid #000;">项目</li>
            <li style="width: 20%;height: 33%;border-bottom: 1px solid #000;border-right: 1px solid #000;">样品数</li>
            <li style="width: 20%;height: 33%;border-bottom: 1px solid #000;border-right: 1px solid #000;">合格数</li>
            <li style="width: 20%;height: 33%;border-bottom: 1px solid #000;border-right: 1px solid #000;">质量说明</li>
            <li style="width: 19.637%;height: 33%;border-bottom: 1px solid #000;border-right:none;">操作者</li>
            <li style="width: 20%;height: 33%;border-bottom: 1px solid #000;border-right: 1px solid #000;">首件封帽</li>
            <li style="width: 20%;height: 33%;border-bottom: 1px solid #000;border-right: 1px solid #000;">
                <textarea name="Field10" id="Field10" style="width: 80%;height: 80%;border:none;outline: none;font-size: 14px;font-weight: 600;"></textarea>
            </li>
            <li style="width: 20%;height: 33%;border-bottom: 1px solid #000;border-right: 1px solid #000;">
                <textarea name="Field11" id="Field11" style="width: 80%;height: 80%;border:none;outline: none;font-size: 14px;font-weight: 600;"></textarea>
            </li>
            <li style="width: 20%;height: 33%;border-bottom: 1px solid #000;border-right: 1px solid #000;">
                <textarea name="Field12" id="Field12" style="width: 80%;height: 80%;border:none;outline: none;font-size: 14px;font-weight: 600;"></textarea>
            </li>
            <li style="width: 19.637%;height: 33%;border-bottom: 1px solid #000;border-right:none;">
                <textarea name="Field13" id="Field13" style="width: 80%;height: 80%;border:none;outline: none;font-size: 14px;font-weight: 600;"></textarea>
            </li>
            <li style="width: 20%;height: 33%;border-right: 1px solid #000;">封帽检验</li>
            <li style="width: 20%;height: 33%;border-right: 1px solid #000;">
                <textarea name="Field14" id="Field14" style="width: 80%;height: 80%;border:none;outline: none;font-size: 14px;font-weight: 600;"></textarea>
            </li>
            <li style="width: 20%;height: 33%;border-right: 1px solid #000;">
                <textarea name="Field15" id="Field15" style="width: 80%;height: 80%;border:none;outline: none;font-size: 14px;font-weight: 600;"></textarea>
            </li>
            <li style="width: 20%;height: 33%;border-right: 1px solid #000;">
                <textarea name="Field16" id="Field16" style="width: 80%;height: 80%;border:none;outline: none;font-size: 14px;font-weight: 600;"></textarea>
            </li>
            <li style="width: 19.637%;height: 33%;border-right:none;">
                <textarea name="Field17" id="Field17" style="width: 80%;height: 80%;border:none;outline: none;font-size: 14px;font-weight: 600;"></textarea>
            </li>
        </ul>
        <div class="row5">
            <div class="row5_1">
                检验结论:
            </div>
            <div class="row5_2">
                <textarea name="Field18" id="Field18" style="border:none;width: 100%;height: 80%;font-size: 14px;font-weight: 600;outline: none;"></textarea>
            </div>
        </div>
        <div class="row6">
            <div class="row6_1">
                检验员:<input type="text" name="Field19" id="Field19" style="border: none;width:400px;height: 60%;font-size: 14px;font-weight: 600;outline: none;">
            </div>
            <div class="row6_2">
                日期：<input type="text" name="Field20" id="Field20" style="border: none;width:400px;height: 60%;font-size: 14px;font-weight: 600;outline: none;">
            </div>
        </div>
        <div class="row7">
            <div class="row7_1">
                异常分析
            </div>
            <div class="row7_2">
                <textarea name="Field21" id="Field21" style="border:none;width: 95%;height: 80%;font-size: 14px;font-weight: 600;outline: none;"></textarea>
            </div>
        </div>
        <div class="layui-form-item">
            <div class="layui-input-block">
                <button class="layui-btn" lay-submit="" lay-filter="demo1">立即提交</button>
                <button type="reset" class="layui-btn layui-btn-primary">重置</button>
            </div>
        </div>

    </form>

       <script src="~/layui/layui.js"></script>
        <script>
            layui.use(['form', 'layedit', 'laydate', 'jquery'], function () {
                var form = layui.form
                    , layer = layui.layer
                    , layedit = layui.layedit
                    , laydate = layui.laydate
                    , $ = layui.jquery;

                form.on('submit(demo1)', function (data) {
                    $.ajax({
                        url: '@Url.Action("BillProDetailsAsync", "Commons")',
                        type: 'post',
                        dataType: 'json',
                        data: data.field,
                        success: function (data) {
                            console.log(data);
                            //Info,Success,Warning,Error
                            var type = data.Type;
                            if (type == 1) {
                                layer.msg(data.Content, { icon: 6, time: 2000 },
                                    function () {
                                        var index = parent.layer.getFrameIndex(window.name);
                                        parent.layer.close(index);
                                    });

                            } else {
                                layer.alert(data.Content, { icon: 5 });
                            }
                        }
                    });
                    //layer.alert(JSON.stringify(data.field), {
                    //    title: '最终的提交信息'
                    //})
                    return false;
                });

                form.val('example', {
                    "ID": "@ViewBag.model.ID"
                        , "BillNameID": "@ViewBag.BillNameID"
                        , "BillProID": "@ViewBag.ProID"
                        , "Field1": `@Html.Raw(ViewBag.model.Field1)`
                        , "Field2": `@Html.Raw(ViewBag.model.Field2)`
                        , "Field3": `@Html.Raw(ViewBag.model.Field3)`
                        , "Field4": `@Html.Raw(ViewBag.model.Field4)`
                        , "Field5": `@Html.Raw(ViewBag.model.Field5)`
                        , "Field6": `@Html.Raw(ViewBag.model.Field6)`
                        , "Field7": `@Html.Raw(ViewBag.model.Field7)`
                        , "Field8": `@Html.Raw(ViewBag.model.Field8)`
                        , "Field9": `@Html.Raw(ViewBag.model.Field9)`
                        , "Field10": `@Html.Raw(ViewBag.model.Field10)`
                        , "Field11": `@Html.Raw(ViewBag.model.Field11)`
                        , "Field12": `@Html.Raw(ViewBag.model.Field12)`
                        , "Field13": `@Html.Raw(ViewBag.model.Field13)`
                        , "Field14": `@Html.Raw(ViewBag.model.Field14)`
                        , "Field15": `@Html.Raw(ViewBag.model.Field15)`
                        , "Field16": `@Html.Raw(ViewBag.model.Field16)`
                        , "Field17": `@Html.Raw(ViewBag.model.Field17)`
                        , "Field18": `@Html.Raw(ViewBag.model.Field18)`
                        , "Field19": `@Html.Raw(ViewBag.model.Field19)`
                        , "Field20": `@Html.Raw(ViewBag.model.Field20)`
                        , "Field21": `@Html.Raw(ViewBag.model.Field21)`
                        @*, "Field22": `@Html.Raw(ViewBag.model.Field22)`
                        , "Field23": `@Html.Raw(ViewBag.model.Field23)`
                        , "Field24": `@Html.Raw(ViewBag.model.Field24)`
                        , "Field25": `@Html.Raw(ViewBag.model.Field25)`
                        , "Field26": `@Html.Raw(ViewBag.model.Field26)`
                        , "Field27": `@Html.Raw(ViewBag.model.Field27)`
                        , "Field28": `@Html.Raw(ViewBag.model.Field28)`
                        , "Field29": `@Html.Raw(ViewBag.model.Field29)`*@
                })

            });
        </script>
</body>
</html>